package com.zbkj.front.service.impl.mszs;

import com.zbkj.common.constants.Constants;
import com.zbkj.common.request.PageParamRequest;
import com.zbkj.common.request.mszs.MszsIndexRequest;
import com.zbkj.common.response.mszs.MszsIndexInfoResponse;
import com.zbkj.front.service.mszs.MszsIndexService;
import com.zbkj.service.service.config.SystemGroupDataService;
import com.zbkj.service.service.mszs.MszsHotelService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 民宿助手移动端-首页数据-相关接口实现类
 * @author lingfe
 */
@Service
public class MszsIndexServiceImpl implements MszsIndexService {

    private static final Logger logger = LoggerFactory.getLogger(MszsIndexServiceImpl.class);

    @Autowired
    private SystemGroupDataService systemGroupDataService;
    @Autowired
    private MszsHotelService hotelService;

    @Override
    public MszsIndexInfoResponse getIndexDate(MszsIndexRequest request, PageParamRequest pageParamRequest) {
        MszsIndexInfoResponse indexInfoResponse = new MszsIndexInfoResponse();
        indexInfoResponse.setBanner(systemGroupDataService.getListMapByGid(Constants.GROUP_DATA_ID_MSZS_INDEX_BANNER));
        //indexInfoResponse.setHotel(hotelService.hotelList(request,pageParamRequest));
        indexInfoResponse.setHotel(hotelService.hotelListReconfiguration(request,pageParamRequest));
        return indexInfoResponse;
    }
}
